package com.thjk.bdf.preloan.web.enums;

/**
 * 错误枚举
 * @author xuanwy
 *
 */
public enum InvoiceEnum {
	Error_1003_1("1003-1","很抱歉，暂未查询到税务信息,请先下载发票采集工具。"),
	Error_1003_2("1003-2","发票信息传输中，请稍后再试。"),
	;
	
    
	private String code;
	private String desc;
	
	
	public String getCode() {
		return code;
	}


	public void setCode(String code) {
		this.code = code;
	}


	public String getDesc() {
		return desc;
	}


	public void setDesc(String desc) {
		this.desc = desc;
	}
	
	InvoiceEnum(String code,String desc) {
		this.code = code;
		this.desc = desc;
	}
	
	public static String getRetValue(String value) {
		if (value != null) {
			for (InvoiceEnum nameEnum : values()) {
				if (nameEnum.getCode().equals(value)) {
					return nameEnum.desc;
				}
			}
		}
		return null;
	}
}
